//
//  LoginFirView.m
//  A_program
//
//  Created by 杨利佳 on 15/5/27.
//  Copyright (c) 2015年 BayMax. All rights reserved.
//

#import "LoginFirView.h"


@implementation LoginFirView
- (void)dealloc
{
    [self.user release];
    [super dealloc];
}
- (instancetype)initWithFrame:(CGRect)frame
{
    if (self = [super initWithFrame:frame]) {
        [self createSubviews];
    }
    return self;
}

- (void)createSubviews
{
    UIImageView *background = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
    [background setBackgroundColor:[UIColor colorWithPatternImage:[UIImage imageNamed:@"Loginbackground_123456.jpg"]]];
    [self addSubview:background];
    [background release];
    
    
    self.user = [[UILabel alloc] initWithFrame:CGRectMake(self.frame.size.width / 2 - 100, 190, 200, 20)];
    self.user.center = CGPointMake(self.frame.size.width / 2, 130);
    self.user.textAlignment = NSTextAlignmentCenter;
    [background addSubview:_user];
    [_user release];
    
}


/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
